package com.monlyu.action.programming;

import java.io.InputStream;
import java.util.List;

import com.monlyu.action.system.DownloadAction;
import com.monlyu.bo.ProgrammingBo;
import com.monlyu.vo.Manuscript;
import com.monlyu.vo.Programming;

/*******************************************************************************
 * 
 * <b>功能描述☞</b>新闻编排节目单的查询<br>
 * 
 * <b>开发公司☞</b>重庆唯尼科技有限公司<br>
 * <b>版权☞</b>本文件归重庆唯尼科技有限公司所有<br>
 * <b>项目名☞</b>news<br>
 * <b>文件路径☞</b>com.monlyu.action.programming.ProgramAction.java<br>
 * <b>开发日期☞</b>2010-2-11 <br>
 * 
 * @author chendan
 * @since JDK 5
 * @version 1.0.8
 * 
 ******************************************************************************/
public class DownloadProgramAction extends DownloadAction {

	/** 稿件列表 */
	private List<Manuscript> manuscripts;

	/** 编排的节目单 */
	private Programming programming;

	private ProgrammingBo programmingBo;
	private InputStream inputStream;

	@Override
	public String execute() throws Exception {
		
		filename = "每日稿件串播表";
		inputStream = programmingBo.exportProgram(programming);
		return download("xls");
	}

	public void setProgrammingBo(ProgrammingBo programmingBo) {
		this.programmingBo = programmingBo;
	}

	public List<Manuscript> getManuscripts() {
		return manuscripts;
	}

	public void setManuscripts(List<Manuscript> manuscripts) {
		this.manuscripts = manuscripts;
	}

	public Programming getProgramming() {
		return programming;
	}

	public void setProgramming(Programming programming) {
		this.programming = programming;
	}

	public InputStream getInputStream() {
		return inputStream;
	}

	public void setInputStream(InputStream inputStream) {
		this.inputStream = inputStream;
	}

}
